cmake_minimum_required(VERSION 3.5)
set(projectName BaseSubsystemPlugin)
project(${projectName} LANGUAGES CXX C VERSION 1.0.0)

set(src_code
    src/AStar/AStarVector3.cpp
    src/AStar/AStarWorldVector3.cpp

    src/BaseSubsystemPlugin.cpp
    src/SubsystemExplosionsBase.cpp
    src/SubsystemBoatBlockBehavior.cpp
    src/SubsystemEggBlockBehavior.cpp
    src/SubsystemPathfinding.cpp
    src/Segment2.cpp
    src/ComponentWalkAroundBehavior.cpp
    src/ComponentPathfinding.cpp
    src/ComponentPilot.cpp
    src/ComponentBehaviorSelector.cpp
    src/ComponentFlyAroundBehavior.cpp
    src/ComponentFlyAwayBehavior.cpp
    src/ComponentLookAroundBehavior.cpp
    src/ComponentRandomPeckBehavior.cpp
    src/ComponentMoveAwayBehavior.cpp
    src/ComponentLayEggBehavior.cpp
    src/ComponentEatPickableBehavior.cpp
    src/ComponentSwimAroundBehavior.cpp
    src/ComponentSwimAwayBehavior.cpp
    src/ComponentFishOutOfWaterBehavior.cpp
    src/ComponentStareBehavior.cpp
    src/ComponentHerdBehavior.cpp
    src/ComponentRandomFeedBehavior.cpp
    src/ComponentUdder.cpp
    src/ComponentShapeshifter.cpp
    src/ComponentRunAwayBehavior.cpp
    src/ComponentNoiseListener.cpp

    src/SubsystemAnimalEntitiesBase.cpp
    src/SubsystemBodiesBase.cpp
    src/SubsystemNoise.cpp
    src/SubsystemCreatureSpawn.cpp




    src/SubsystemExplosivesBlockBehavior.cpp
    src/SubsystemFurnitureBlockBehavior.cpp
    src/SubsystemMagnetBlockBehavior.cpp
    src/SubsystemMemoryBankBlockBehavior.cpp

)

include_directories(include/BaseSubsystemPlugin)

add_library(${projectName} SHARED ${src_code})
target_link_libraries(${projectName} PUBLIC PocketSurvival)

set_target_properties(${projectName} PROPERTIES INSTALL_RPATH "$ORIGIN")

target_include_directories(${projectName} PUBLIC "$<BUILD_INTERFACE:${CMAKE_CURRENT_LIST_DIR}/include>" "$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>")




